import request from '@/utils/request'

// 获取所有标签类别名称list
export function getLabelTypeById(id) {
  return request({
    url: '/material/labelType/findLabelTypeNameByid/'+id,
    method: 'get',
  })
}

// 获取所有标签类别名称list
export function typeListShow() {
  return request({
    url: '/material/labelType/typeList',
    method: 'get',
  })
}
// 查询标签类别列表
export function listLabelType(query) {
  return request({
    url: '/material/labelType/list',
    method: 'get',
    params: query
  })
}

// 查询标签类别详细
export function getLabelType(id) {
  return request({
    url: '/material/labelType/' + id,
    method: 'get'
  })
}

// 新增标签类别
export function addLabelType(data) {
  return request({
    url: '/material/labelType',
    method: 'post',
    data: data
  })
}

// 修改标签类别
export function updateLabelType(data) {
  return request({
    url: '/material/labelType',
    method: 'put',
    data: data
  })
}

// 删除标签类别
export function delLabelType(id) {
  return request({
    url: '/material/labelType/' + id,
    method: 'delete'
  })
}

// 导出标签类别
export function exportLabelType(query) {
  return request({
    url: '/material/labelType/export',
    method: 'get',
    params: query
  })
}
